@echo off

if "%1"=="--help" (
	echo mapdrvs - Map the network drives of REUTERS
	echo usage: mapdrvs [--help ^| --remove]
	echo        --help   - show this help message
	echo        --remove - remove all mapped drives of REUTERS
	goto _end_
)

set Bjzsapacfs1=10.35.1.60
set Bjzsapacfs2=10.35.1.61

set Domain=TEN
set Username=U8005367

if exist B:\ net use B: /delete
if exist H:\ net use H: /delete
if exist S:\ net use S: /delete
if exist Z:\ net use Z: /delete

if "%1"=="--remove" (
	goto _end_
) else (
	if not "%1" == "" (
		set Password=%1
	) else (
		set /p Password="Password: "
	)
)

echo Map drive H: - Home Drive
net use H: \\%Bjzsapacfs1%\Ken.Zhang$ /user:%Domain%\%Username% %Password%

echo Map drive B: - for IDN
net use B: \\%Bjzsapacfs2%\idn$ /user:%Domain%\%Username% %Password%

echo Map drive S: - The debug symbols
net use S: \\%Bjzsapacfs2%\Debug_symbol$ /user:%Domain%\%Username% %Password%

echo Map drive Z: - for ADD
net use Z: \\%Bjzsapacfs2%\Add$ /user:%Domain%\%Username% %Password%

:_end_
